<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<#include "/views/ftl/base/manager_include.ftl">
<base href="${basePath }" /> 
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>银行管理</title>
<script type="text/javascript">
$().ready(function() {
	$("#search_button").click(function(){
		$('#select_form').submit();
    });
});

</script>
<script>
function del(id){
var msg="确定要删除吗？";
 if(confirm(msg))
   {
    $.ajax({
		type : 'post',
		url:"${basePath }manager/Bank_deleteBank",
		dataType : "json",
		data : {bankId:id},
		success : function(data) {
		  	alert(data.msg);
			if(data.code==1){
			$("#pagerForm").submit();
			}
		}
	});
	}
}
</script>
</head>
<body style="background:#eef3f7;">
<#include "/views/ftl/base/head.ftl">
<div class="Main">
  <div class="dw">
<#include "/views/ftl/base/menu.ftl">
<#function a><#return "银行列表_List"></#function> 
<!--右边内容-->
      <div class="Rightbox fl">
        <!--面包屑-->
        <div class="Bread_crbs clear">
          <div class="Bread_crbs_img fl"></div>
          <div class="Bread_crbs_text fl"><a href="javascript:void(0);"><span>银行管理</span></a><span class="fnt_famy">></span><a href="javascript:void(0);"><span>银行列表</span></a></div>
        </div>
        <!--搜索框-->
        <form action="${basePath }manager/Bank_bankList" method="POST" id="select_form">
        	<span class="fl searchTitle" style="font-size: 14px;color: #333333;">银行名称:</span>
        	<div class="searchBox fl">
          		<div class="search_img fl"></div>
          		<input class="search_text" type="text" name="bankName" placeholder="请输入关键字" value="${(bankName)!'' }"/>  
        	</div>
        	 	<div class="searchBox fl">
        	<span class="fl searchTitle" style="font-size: 14px;color: #333333;">银行类型:</span>
           <select name="bankType"  class="sp">
           	<option value="3" <#if bankType==3>selected='true'</#if>>全部</option>
					<option value="1" <#if bankType==1>selected='true'</#if>>银行</option>
					<option value="2" <#if bankType==2>selected='true'</#if>>交易平台</option>
			</select>
			</div>
       <a id="search_button" class="search_btn fl" href="javascript:void(0);"><span>搜索</span></a>
       <a class="added fl" href="javascript:add();"><span>新增</span></a>     
        </form>
        
       
        <div class="clear"></div>  
        <!--表格列表-->
        <div class="Table">
          <table id="table" cellpadding="0" cellspacing="1">
            <tbody>
              <tr id="gl">
             <td>名称</td>
             <td>图标</td>
             <td>类型</td>
             <td>创建时间</td>
             <td>排序</td>
             <td>操作</td>
              </tr>
         <#if (pager.list??)> 
         <#if ((pager.list?size)>0)>
          <#list pager.list as bank>
      
     		<tr>
			<td>${(bank.bankName)!''}</td>
          	<td><img id="i1" src="${(bank.bankLogo)!''}" height="100" width="100"></td>
            <td>
            <#if bank.bankType==1>银行</#if>
            <#if bank.bankType==2>交易平台</#if>
            </td>
            <td>
            ${(bank.createTime)!''}
            </td>
            <td>${(bank.indexNo)!''}</td>
             <td class="tbl_btn tdd100">
         		<a href="${basePath}manager/Bank_toUpdateBank?bankId=${(bank.id?c)}"><span id="editor">编辑</span></a>
         		<a href="javascript:del(${(bank.id?c)});"><span id="red">删除</span></a>
</td>
              </tr>
           </#list >
          </#if>
          </#if> 
            
            </tbody>
          </table>
        </div>

	    <!--翻页按钮-->
  	<#import "../../base/pager.ftl" as p>
   	<@p.pager pager = pager baseUrl = "manager/Bank_bankList" parameterMap={"bankName":(bankName)!'',"bankType":(bankType?c)!''} />
      </div> 
   </div>
  
</div>
</body>
</html>
<script type="text/javascript">
function add()
{
	window.location.href= "${basePath }manager/Bank_toAddBank";
}

</script>



